package com.bawei.mvc.Pertion;

import android.view.View;

import com.bawei.mvc.Moude.IMoudel;
import com.bawei.mvc.View.IView;

/**
 * create by ertu
 * create on 2021/7/18
 * description
 */
public class BasePresenter<M extends IMoudel,V extends IView>implements IPresenter{

    protected  M mModel;
    protected V mView;

    public BasePresenter(M mModel, V mView) {
        this.mModel = mModel;
        this.mView = mView;
    }

    @Override
    public void dinst() {
        if (mModel!=null)
        {
            mModel =null;
            mModel.destroy();
        }
        if (mView!=null)
        {
            mView=null;
        }
    }
}
